/**
 * Created by liu on 2018/3/27.
 */
import axios from '../../../api/api';
import { post } from '../../../api/myAxios';

export const getReaderInfo= params => {
    return axios.get(`/api/reader/detail?id=`+params)
        .then(bookInfo => bookInfo.data)
};

export const create = params => {
    let param = {
        url:'/api/reader/add',
        data: params
    };
    return post(param).then(data => data)
};

export const edit = params => {
    let param = {
        url:'/api/reader/edit',
        data: params
    };
    return post(param).then(data => data)
};


export const login = params => {
    console.log(params);
    let param = {
        url:'/api/reader/login',
        data: params
    };
    return post(param)
};


